define(()=>{
    return function(res, goods, box){
        // res[i].proId === goods[j].id
        let str = "";
        res.forEach(val1=>{
            goods.forEach(val2=>{
                if(val1.proId === val2.id){
                    str += `<tr index="${val1.proId}">
                            <td><input type="checkbox" class="setCheck" ${val2.flag ? 'checked' : ''}></td>
                            <td><img src="${val1.img}" alt=""></td>
                            <td>${val1.proName}</td>
                            <td><input type="number" class="setNum" value="${val2.num}"></td>
                            <td>${val1.price}</td>
                            <td>${val1.price * val2.num}</td>
                            <td><input type="button" value="删除" class="del"></td>
                        </tr>`
                }
            })
        })
        box.innerHTML = str;
    }
})